#本部分代码将测试自建任意后缀名的zip文件
import zipfile

bg_Path = "测试.bg"
f1_Path = "这个文件夹放Python.txt"
f2_Path = "测试表.xlsx"
with zipfile.ZipFile(bg_Path,"w") as bg:
    bg.write(f1_Path)
    bg.write(f2_Path)

bg = zipfile.ZipFile(bg_Path)
print(bg.namelist())